<?php
/*
 * [JINYUN!] (C)2001-2099 Jinyunweb.com
 * This is NOT a freeware, use is subject to license terms
 * $Id: 2017-12-13 03:39:35 apple $
 电商客插件菜单
*/
defined('BY_JYA') or exit('error');
$plugins=$this->plugins();
foreach($plugins as $ki=>&$item){
	$item['child']=$item['list'];
	unset($item['list']);
	foreach($item['child'] as $k=>&$p){
		if(!$p['is_install']){
			unset($item['child'][$k]);
		}else{
			if($p['actionurl']){
				$p['url']=$p['actionurl'];
			}else{
				$p['url']=$p['name'].'/basic.module_home/';
			}
		}
	}
}
$menus=array(
	array('title'=>'门店概况','fa'=>'icon-licai','url'=>'jy_yxw/index/','nodiy'=>1,'noonesys'=>1,'child'=>array(
		array('title'=>'概况','child'=>array(
			array('url'=>'jy_yxw/index/','title'=>'门店概况'),
			array('url'=>'jy_yxw/links/','title'=>'链接大全'),
		)),
	)),
	array('title'=>'门店列表','fa'=>'icon-dianpu','url'=>'jy_yxw/store.list/','child'=>array(
		array('title'=>'门店列表','child'=>array(
			array('url'=>'jy_yxw/store.list/','title'=>'门店列表'),
			array('url'=>'jy_yxw/store.isdel/','title'=>'已删除的'),
		)),
	)),
	array('title'=>'会计系统','fa'=>'icon-dixiaofei','url'=>'jy_yxw/caiwu.index/','child'=>array(
		array('title'=>'概况排行','child'=>array(
			array('url'=>'jy_yxw/caiwu.index/','title'=>'总概况'),
		)),
		array('title'=>'成交总表','child'=>array(
			array('url'=>'jy_yxw/caiwu.in/','title'=>'成交总表'),
		)),
		array('title'=>'售后成本','child'=>array(
			array('url'=>'jy_yxw/store.shouben/','title'=>'售后成本'),
		)),
		array('title'=>'实体门店销售','child'=>array(
			array('url'=>'jy_yxw/store.inall/list/','title'=>'实体门店总业绩'),
			array('url'=>'jy_yxw/counts.juese6data//iswang=0','title'=>'销售员排名'),
			array('url'=>'jy_yxw/counts.juese5data//iswang=0','title'=>'电客排名'),
			array('url'=>'jy_yxw/counts.tingdata//iswang=0','title'=>'体验排名'),
			array('url'=>'jy_yxw/counts.xuedata//iswang=0','title'=>'试用排名'),
		)),
		array('title'=>'网络门店销售','child'=>array(
			array('url'=>'jy_yxw/store.inall/list2/','title'=>'网络门店总业绩'),
			array('url'=>'jy_yxw/counts.juese6data//iswang=1','title'=>'销售员排名'),
			array('url'=>'jy_yxw/counts.juese5data//iswang=1','title'=>'电客排名'),
			array('url'=>'jy_yxw/counts.tingdata//iswang=1','title'=>'体验排名'),
			array('url'=>'jy_yxw/counts.xuedata//iswang=1','title'=>'试用排名'),
		)),
		array('title'=>'售后基地排名','child'=>array(
			array('url'=>'jy_yxw/store.inall/list3/','title'=>'售后门店总业绩'),
			array('url'=>'jy_yxw/counts.koubeirank/','title'=>'口碑销售排名'),
		)),
	)),
	array('title'=>'销售部','fa'=>'icon-zhifeiji','url'=>'jy_yxw/counts.buygoods/list/','child'=>array(
			array('title'=>'明细','child'=>array(
				array('url'=>'jy_yxw/counts.buygoods/list/','title'=>'成交明细'),
				array('url'=>'jy_yxw/counts.buygoods/list2/','title'=>'定金明细'),
				array('url'=>'jy_yxw/counts.buygoods/list4/','title'=>'退费明细'),
				array('url'=>'jy_yxw/counts.member/shmen/','title'=>'意向明细'),
				array('url'=>'jy_yxw/counts.member/tingnum/','title'=>'体验明细'),
				array('url'=>'jy_yxw/counts.member/tingnum2/','title'=>'体用明细'),
				array('url'=>'jy_yxw/counts.member/xuenum/','title'=>'试用明细'),
			)),
	)),
	array('title'=>'客户池','fa'=>'icon-licai','url'=>'jy_yxw/member.list//jibie_type=all','child'=>array(
		array('title'=>'按级别','child'=>array(
			array('url'=>'jy_yxw/member.list//jibie_type=all','title'=>'全量客户'),
			array('url'=>'jy_yxw/member.list//jibie_type=0','title'=>'待归类'),
			array('url'=>'jy_yxw/member.list//jibie_type=1','title'=>'A类客户'),
			array('url'=>'jy_yxw/member.list//jibie_type=2','title'=>'B类客户'),
			array('url'=>'jy_yxw/member.list//jibie_type=3','title'=>'C类客户'),
			array('url'=>'jy_yxw/member.list//jibie_type=4','title'=>'D类客户'),
			array('url'=>'jy_yxw/member.list//jibie_type=5','title'=>'无效客户'),
		)),
		array('title'=>'按渠道','child'=>array(
			array('url'=>'jy_yxw/member.fromlist//from_type=1','title'=>'线下来源渠道'),
			array('url'=>'jy_yxw/member.fromlist//from_type=2','title'=>'网络来源渠道'),
		)),
		array('title'=>'按进度','child'=>array(
			array('url'=>'jy_yxw/member.jindulist//status=0','title'=>'初入客户'),
			array('url'=>'jy_yxw/member.jindulist//status=1','title'=>'待电客'),
			array('url'=>'jy_yxw/member.jindulist//status=2','title'=>'跟进中'),
			array('url'=>'jy_yxw/member.jindulist//status=3','title'=>'准意向'),
			array('url'=>'jy_yxw/member.jindulist//status=4','title'=>'已意向'),
			array('url'=>'jy_yxw/member.jindulist//status=5','title'=>'待体验'),
			array('url'=>'jy_yxw/member.jindulist//status=6','title'=>'已体验'),
			array('url'=>'jy_yxw/member.jindulist//status=7','title'=>'待体用'),
			array('url'=>'jy_yxw/member.jindulist//status=8','title'=>'已体用'),
		)),
	)),
	array('title'=>'售后管理','fa'=>'icon-lianxishangjia','url'=>'jy_yxw/yonghu.index/','child'=>array(
		array('title'=>'概况','child'=>array(
			array('url'=>'jy_yxw/yonghu.index/','title'=>'概况'),
		)),
		array('title'=>'售后群','child'=>array(
			array('url'=>'jy_yxw/yonghu.class/','title'=>'售后群'),
			array('url'=>'jy_yxw/yonghu.weiji/','title'=>'违纪情况'),
		)),
		array('title'=>'按门店','child'=>array(
			array('url'=>'jy_yxw/yonghu.storedata/','title'=>'门店概况'),
		)),
		array('title'=>'按反馈','child'=>array(
			array('url'=>'jy_yxw/yonghu.list//status=all','title'=>'全部用户'),
			array('url'=>'jy_yxw/yonghu.list//status=13','title'=>'待反馈用户'),
			array('url'=>'jy_yxw/yonghu.list//status=14','title'=>'已反馈用户'),
			array('url'=>'jy_yxw/yonghu.list//status=21','title'=>'二次反馈用户'),
			array('url'=>'jy_yxw/yonghu.list//status=22','title'=>'问题反馈用户'),
			array('url'=>'jy_yxw/yonghu.list//status=23','title'=>'取消放弃反馈'),
			array('url'=>'jy_yxw/yonghu.list//status=24','title'=>'延迟反馈用户'),
		)),
	)),
	array('title'=>'员工管理','fa'=>'icon-paihao0','url'=>'jy_yxw/worker.listall/','child'=>array(
		array('title'=>'员工','child'=>array(
			array('url'=>'jy_yxw/worker.listall/','title'=>'全部员工'),
			array('url'=>'jy_yxw/worker.list//juese=18','title'=>'总部'),
		)),
		array('title'=>'角色','child'=>array(
			array('url'=>'jy_yxw/worker.list15/','title'=>'区域经理列表'),
			array('url'=>'jy_yxw/worker.liststore//juese=1','title'=>'店长列表'),
			array('url'=>'jy_yxw/worker.liststore//juese=2','title'=>'主管列表'),
			array('url'=>'jy_yxw/worker.list//juese=14','title'=>'出纳'),
			array('url'=>'jy_yxw/worker.list//juese=17','title'=>'会计'),
			array('url'=>'jy_yxw/worker.liststore//juese=4','title'=>'客服文员'),
			array('url'=>'jy_yxw/worker.liststore//juese=5','title'=>'电话客服'),
			array('url'=>'jy_yxw/worker.liststore//juese=6','title'=>'销售员'),
			array('url'=>'jy_yxw/worker.liststore//juese=7','title'=>'体验师'),
			array('url'=>'jy_yxw/worker.liststore//juese=8','title'=>'试用师'),
			array('url'=>'jy_yxw/worker.liststore//juese=9','title'=>'售后助理'),
			array('url'=>'jy_yxw/worker.liststore//juese=10','title'=>'售后技术'),
			array('url'=>'jy_yxw/worker.liststore//juese=11','title'=>'售后主管'),
			array('url'=>'jy_yxw/worker.liststore//juese=12','title'=>'售后反馈'),
			array('url'=>'jy_yxw/worker.list//juese=16','title'=>'财务主管'),
			array('url'=>'jy_yxw/worker.liststore//juese=20','title'=>'仓管员'),
			array('url'=>'jy_yxw/worker.liststore//juese=21','title'=>'入库员'),
			array('url'=>'jy_yxw/worker.liststore//juese=22','title'=>'出库员'),
		)),
	)),
	array('title'=>'应用','isplugin'=>1,'fa'=>'icon-box','url'=>'jy_yxw/plugins/','child'=>$plugins),
	array('title'=>'设置','fa'=>'icon-shezhi','url'=>'jy_yxw/setting/','child'=>array(
		array('title'=>'基础设置','child'=>array(
			array('url'=>'jy_yxw/setting/','title'=>'基础设置'),
			array('url'=>'core/wechat.list/','title'=>'公众号管理'),
		)),
		array('title'=>'消息提醒','child'=>array(
			array('url'=>'core/setting.msgset/list/plugin_name=jy_yxw','title'=>'消息开启设置'),
			array('url'=>'core/setting.msgtpl/list/plugin_name=jy_yxw','title'=>'微信模板库'),
		)),
		array('title'=>'短信配置','child'=>array(
			array('url'=>'core/setting.sms_temp/','title'=>'短信消息库'),
		)),
	)),
	array('title'=>'操作权限','fa'=>'icon-listzuhe','url'=>'core/basic.plugin_perm//plugin_name=jy_yxw','child'=>array(
		array('title'=>'操作权限','child'=>array(
			array('url'=>'core/account.operator/','title'=>'站点操作员'),
			array('url'=>'core/basic.plugin_perm//plugin_name=jy_yxw','title'=>'应用操作权限'),
		)),
	)),
);
if($_SESSION['isfounder']){
	$menus[]=array('title'=>'程序升级','fa'=>'icon-box','url'=>'core/cloud.update/','child'=>array(
			array('title'=>'升级','child'=>array(
				array('url'=>'core/cloud.update/','title'=>'框架升级'),
				array('url'=>'core/cloud.app_update//name=jy_yxw','title'=>'应用升级'),
				array('url'=>'core/cloud.app_uplog//name=jy_yxw','title'=>'更新日志'),
				array('url'=>'core/system.cache/','title'=>'更新缓存'),
			)),
	));
}
return $menus;